from flyweightpattern.flyweight import Flyweight


class ConcreteFlyweight(Flyweight):

    def __init__(self, key):
        self.key = key
        print('享元' + key + '被创建')

    def operation(self, unshared):
        print('享元' + self.key)
        print('非享元' + unshared.get_info())
